<!DOCTYPE html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>10.1</title>
	<script src="js/vue.js"></script>
	</head>
	<body>
		<div id="app">
			<input type="text" v-model="msg">
			{{msg\upperCase\asterisk}}
		</div>
	</body>
	<script>
		Vue.filter('upperCase',function(val){
			return val.toUpperCase();
		})
		Vue.filter('asterisk',function(val){
			var reg = /\d/g;
			return val.replace(reg,'*');
		})
		var app = new Vue({
			el: '#app',
			data: {
				msg: ' '
			},
		});
	</script>
</html>